// components/business/popup/popup.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    hidePopup:{
      type: Boolean,
      value: true
    },
    lists:{
      type: Array,
      value: []
    },
    title:{
      type: String,
      value: ""
    }
  },

  /**
   * 组件的初始数据
   */
  data: {
    isActive:""
  },

  /**
   * 组件的方法列表
   */
  methods: {
    closePopupTap(){
      this.setData({
        hidePopup:true
      })
    },
    tap(e){
      let item = e.currentTarget.dataset.item;
      this.setData({
        isActive:item
      })
    },
    confrim(){
      this.triggerEvent('selected', this.data.isActive)
      this.setData({
        hidePopup:true
      })
    }
  }
})
